package com.demo.study;

import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.Bean;
import org.springframework.web.bind.annotation.RestController;

import java.util.Arrays;

/**
 * @author sz
 * @version V1.0
 * @date 2023/12/24 16:30
 * @Description: 多敲代码
 */

@RestController
@SpringBootApplication
public class SpringbootDemoApplication {

    public static void main(String[] args) {
        SpringApplication.run(SpringbootDemoApplication.class);

    }



    @Bean
    public CommandLineRunner commandLineRunner(ApplicationContext ctx) {
        // 目的是
        return args -> {
            //System.out.println("来看看 SpringBoot 默认为我们提供的 Bean：");
            String[] beanNames = ctx.getBeanDefinitionNames();
            Arrays.sort(beanNames);
           // Arrays.stream(beanNames).forEach(System.out::println);
        };
    }
    /**
     * basicErrorController
     * beanNameHandlerMapping
     * beanNameViewResolver
     * characterEncodingFilter
     * commandLineRunner
     * conventionErrorViewResolver
     * defaultServletHandlerMapping
     * defaultValidator
     * defaultViewResolver
     * dispatcherServlet
     * dispatcherServletRegistration
     * error
     * errorAttributes
     * errorPageCustomizer
     * errorPageRegistrarBeanPostProcessor
     * faviconHandlerMapping
     * faviconRequestHandler
     * handlerExceptionResolver
     * hiddenHttpMethodFilter
     * httpPutFormContentFilter
     * httpRequestHandlerAdapter
     * jacksonCodecCustomizer
     * jacksonObjectMapper
     * jacksonObjectMapperBuilder
     * jsonComponentModule
     * localeCharsetMappingsCustomizer
     * mappingJackson2HttpMessageConverter
     * mbeanExporter
     * mbeanServer
     * messageConverters
     * methodValidationPostProcessor
     * multipartConfigElement
     * multipartResolver
     * mvcContentNegotiationManager
     * mvcConversionService
     * mvcHandlerMappingIntrospector
     * mvcPathMatcher
     * mvcResourceUrlProvider
     * mvcUriComponentsContributor
     * mvcUrlPathHelper
     * mvcValidator
     * mvcViewResolver
     * objectNamingStrategy
     * org.springframework.boot.autoconfigure.AutoConfigurationPackages
     * org.springframework.boot.autoconfigure.admin.SpringApplicationAdminJmxAutoConfiguration
     * org.springframework.boot.autoconfigure.condition.BeanTypeRegistry
     * org.springframework.boot.autoconfigure.context.ConfigurationPropertiesAutoConfiguration
     * org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration
     * org.springframework.boot.autoconfigure.http.HttpMessageConvertersAutoConfiguration
     * org.springframework.boot.autoconfigure.http.HttpMessageConvertersAutoConfiguration$StringHttpMessageConverterConfiguration
     * org.springframework.boot.autoconfigure.http.JacksonHttpMessageConvertersConfiguration
     * org.springframework.boot.autoconfigure.http.JacksonHttpMessageConvertersConfiguration$MappingJackson2HttpMessageConverterConfiguration
     * org.springframework.boot.autoconfigure.http.codec.CodecsAutoConfiguration
     * org.springframework.boot.autoconfigure.http.codec.CodecsAutoConfiguration$JacksonCodecConfiguration
     * org.springframework.boot.autoconfigure.info.ProjectInfoAutoConfiguration
     * org.springframework.boot.autoconfigure.internalCachingMetadataReaderFactory
     * org.springframework.boot.autoconfigure.jackson.JacksonAutoConfiguration
     * org.springframework.boot.autoconfigure.jackson.JacksonAutoConfiguration$Jackson2ObjectMapperBuilderCustomizerConfiguration
     * org.springframework.boot.autoconfigure.jackson.JacksonAutoConfiguration$JacksonObjectMapperBuilderConfiguration
     * org.springframework.boot.autoconfigure.jackson.JacksonAutoConfiguration$JacksonObjectMapperConfiguration
     * org.springframework.boot.autoconfigure.jackson.JacksonAutoConfiguration$ParameterNamesModuleConfiguration
     * org.springframework.boot.autoconfigure.jmx.JmxAutoConfiguration
     * org.springframework.boot.autoconfigure.security.reactive.ReactiveSecurityAutoConfiguration
     * org.springframework.boot.autoconfigure.validation.ValidationAutoConfiguration
     * org.springframework.boot.autoconfigure.web.client.RestTemplateAutoConfiguration
     * org.springframework.boot.autoconfigure.web.embedded.EmbeddedWebServerFactoryCustomizerAutoConfiguration
     * org.springframework.boot.autoconfigure.web.embedded.EmbeddedWebServerFactoryCustomizerAutoConfiguration$TomcatWebServerFactoryCustomizerConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.DispatcherServletAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.DispatcherServletAutoConfiguration$DispatcherServletConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.DispatcherServletAutoConfiguration$DispatcherServletRegistrationConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.HttpEncodingAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.MultipartAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.ServletWebServerFactoryAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.ServletWebServerFactoryConfiguration$EmbeddedTomcat
     * org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$WebMvcAutoConfigurationAdapter
     * org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$WebMvcAutoConfigurationAdapter$FaviconConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.error.ErrorMvcAutoConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.error.ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration
     * org.springframework.boot.autoconfigure.web.servlet.error.ErrorMvcAutoConfiguration$WhitelabelErrorViewConfiguration
     * org.springframework.boot.autoconfigure.websocket.servlet.WebSocketServletAutoConfiguration
     * org.springframework.boot.autoconfigure.websocket.servlet.WebSocketServletAutoConfiguration$TomcatWebSocketConfiguration
     * org.springframework.boot.context.properties.ConfigurationBeanFactoryMetadata
     * org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor
     * org.springframework.context.annotation.internalAutowiredAnnotationProcessor
     * org.springframework.context.annotation.internalCommonAnnotationProcessor
     * org.springframework.context.annotation.internalConfigurationAnnotationProcessor
     * org.springframework.context.annotation.internalRequiredAnnotationProcessor
     * org.springframework.context.event.internalEventListenerFactory
     * org.springframework.context.event.internalEventListenerProcessor
     * parameterNamesModule
     * preserveErrorControllerTargetClassPostProcessor
     * propertySourcesPlaceholderConfigurer
     * requestContextFilter
     * requestMappingHandlerAdapter
     * requestMappingHandlerMapping
     * resourceHandlerMapping
     * restTemplateBuilder
     * server-org.springframework.boot.autoconfigure.web.ServerProperties
     * servletWebServerFactoryCustomizer
     * simpleControllerHandlerAdapter
     * spring.http.encoding-org.springframework.boot.autoconfigure.http.HttpEncodingProperties
     * spring.info-org.springframework.boot.autoconfigure.info.ProjectInfoProperties
     * spring.jackson-org.springframework.boot.autoconfigure.jackson.JacksonProperties
     * spring.mvc-org.springframework.boot.autoconfigure.web.servlet.WebMvcProperties
     * spring.resources-org.springframework.boot.autoconfigure.web.ResourceProperties
     * spring.security-org.springframework.boot.autoconfigure.security.SecurityProperties
     * spring.servlet.multipart-org.springframework.boot.autoconfigure.web.servlet.MultipartProperties
     * springApplicationAdminRegistrar
     * springbootDemoApplication
     * standardJacksonObjectMapperBuilderCustomizer
     * stringHttpMessageConverter
     * tomcatServletWebServerFactory
     * tomcatServletWebServerFactoryCustomizer
     * tomcatWebServerFactoryCustomizer
     * viewControllerHandlerMapping
     * viewResolver
     * webServerFactoryCustomizerBeanPostProcessor
     * websocketContainerCustomizer
     * welcomePageHandlerMapping
     */


}
